#ifndef STACK_H
#define STACK_H
#include <dtype.h>
//栈

//栈元素
UNION(CHRT_STACK_ELEM)
{
    uint32 U4;
    uint64 U8;
    ptr PTR;
    byte BYTES[8];
};

//栈结构
STRUCT_P(CHRT_STACK)
{
    int32 ElemCount;//栈元素数量
    CHRT_STACK_ELEM_pt StackTop;//栈顶指针
    CHRT_STACK_ELEM StackStart[];//栈开始指针，不可更改
};

//新建栈
CHRT_STACK Chvm_New_Stack(int32 size);

#endif
